1. Field of Invention
The present invention relates generally to graphical user interfaces and more specifically to visualizing how content is positioned within a document.
2. Background of Invention
A document is comprised of one or more elements, such as text and objects. A portion of text is made of individual characters. Objects include, for example, images, containers, charts, and tables.
Elements can be nested within each other. An element that is nested within another element is referred to as a “child element.” An element within which another element is nested is referred to as a “parent element.” In other words, a child element is nested within a parent element. Since elements can be nested, they can form a hierarchy of elements. When a document comprises nested elements, the element hierarchy is referred to as a “document tree.”
The element that contains all of the other elements in the hierarchy is referred to as the “root element.” The root element does not have a parent element. All other elements in the hierarchy are child elements, and each one has exactly one parent element. All child elements have at least one “ancestor element,” which refers to the child element's parent element, grandparent element (if any), great-grandparent element (if any), etc., until the root element is reached.
If a parent element contains multiple child elements, the child elements are referred to as “sibling elements.” Sibling elements can be ordered so that each sibling element has a “previous” sibling element and a “next” sibling element (except for the first sibling, which has no previous sibling, and the last sibling, which has no next sibling).
When a document is rendered, each element of the document is positioned somewhere within a two-dimensional area (referred to as a “page”). A page can exist in various forms such as a graphical user interface window (e.g., if the document is rendered using a display device such as a monitor) or a sheet of paper (e.g., if the document is rendered using a printer). The positions of the elements are collectively referred to as the “layout” of the document.
Elements are positioned on a page according to one or more “positioning schemes.” A positioning scheme is a set of rules that defines how an element should be positioned on a page. Since each element can be assigned only one position on a page, each element is associated with exactly one positioning scheme. If a document comprises multiple elements, each element can be associated with a different positioning scheme.
When working with a document, it can be difficult to predict what the layout will be if there are several elements, some of which are associated with different positioning schemes.